package cn.edu.scau.cmi.guihao.domin.abstractFactory;

import cn.edu.scau.cmi.guihao.interProgramming.abstractFactory.Insurance;
import cn.edu.scau.cmi.guihao.interProgramming.abstractFactory.InsuranceCompany;

public class PICC extends InsuranceCompany{
	@Override
	public Insurance createInsurance(String type,String name) {
		if(type=="身体受伤") {
			return new InsuranceInjuryForPICC(name);
		}else if(type=="汽车损坏") {
			return new InsuranceDamageForPICC(name);
		}else {
			return null;
		}
	}
}
